package restful;

import java.util.*;

public class PatternComparator implements Comparator<String> {

	public int compare(String string1, String string2) {
		if (string1.endsWith("(.*)") && !string2.endsWith("(.*)")) return 1;
		if (!string1.endsWith("(.*)") && string2.endsWith("(.*)")) return -1;
		return string1.compareTo(string2);
	}

}
